using System;
using System.Collections.Generic;
using System.Text;

namespace My.IdlConverter.Core.Producers
{
    public class ProducerBase<T> : IProducer<T>
    {
        private T _consumer;

        public ProducerBase()
        {
        }
        public ProducerBase(T consumer) 
        {
            _consumer = consumer;
        }

        public virtual string Produce()
        {
            return Consumer.ToString();
        }

        public virtual T Consumer
        {
            get
            {
                return _consumer;
            }
            set
            {
                _consumer = value;
            }
        }
    }
}
